Learning Semantic Functions of Attribute Grammars
نویسندگان
چکیده
Attribute grammars can be considered as an extension of context-free grammars, where the attributes are associated with grammar symbols, and the semantic rules deene the values of the attributes. This formalism is widely applied for the speciication and implementation of the compilation-oriented languages. The paper presents a method for learning semantic functions of attribute grammars which is a hard problem because semantic functions can also represent relations. The method uses background knowledge in learning semantic functions of S-attributed and L-attributed grammars. The given context-free grammar and the background knowledge allow one to restrict the space of relations and give a smaller representation of data. The basic idea of this method is that the learning problem of semantic functions is transformed to a propositional form and the hypothesis induced by a propositional learner is transformed back into semantic functions.
منابع مشابه
Another Kind of Modular Attribute G
Abst rac t . The decomposition of attribute grammars into modules is investigated. In our approach the alternative rules of a nonterminal may be separated into different modules. The aim of our concept is the generation of special grammars in respect to the design decisions of a compiler writer. Therefore, a module represents a concrete syntactic or semantic design decision~ The importand expor...
متن کاملLazy Combinators for Executable Specifications of General Attribute Grammars
A lazy-evaluation based top-down parsing algorithm has been implemented as a set of higher-order functions (combinators) which support directly-executable specifications of fully general attribute grammars. This approach extends aspects of previous approaches, and allows natural language processors to be constructed as modular and declarative specifications while accommodating ambiguous context...
متن کاملAn Introduction To Attribute Grammars
Beside the syntax, semantic is a very important part of programming languages. Without a semantic a program would no longer be a program but a lifeless sequence of characters which is part of the language. The dynamic semantic properties of a program are determined during execution at runtime. Typically they directly depend on the input values of the program. By contrast the static semantic pro...
متن کاملMarch 1999 { Second Workshop on Attribute Grammars and Their Applications { Waga99 Adding Semantics to Xml
Starting form the analogy between a document tagged by a markup language (XML, SGML) and a source string generated by a BNF grammar, we argue that XML parsers should beneet from the addition of semantic attributes and functions. Currently XML only includes initialized lexical attributes. By our approach a XML parser would be extended into a syntax-directed translator. Deep transformations of a ...
متن کاملA pure embedding of attribute grammars
Attribute grammars are a powerful specification paradigm for many language processing tasks, particularly semantic analysis of programming languages. Recent attribute grammar systems use dynamic scheduling algorithms to evaluate attributes on demand. In this paper, we show how to remove the need for a generator, by embedding a dynamic approach in a modern, object-oriented and functional program...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید
ثبت ناماگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید
ورودعنوان ژورنال:
- Nord. J. Comput.
دوره 4 شماره
صفحات -
تاریخ انتشار 1997